#include <stdio.h>
#include <stdlib.h>



int main ()
{
    int n,count;
    
    scanf("%d",&n);
    count=0;
    
    while(n != 1){
    	if(n%2==1){
    		n= (3*n+1)/2;
		}else{
			n /= 2;
		}
		count++;
	}
	
	printf("%d", count);
	
	
	
    

    return 0 ;
}
